const post = (url,params,success) =>{
    return new Promise((resolve,reject) => {
        axios.post(url,params).then(res => {
            try {
                if(res.status >= 200 && res.status < 300){
                    var rs;
                    success(res,resolve,reject);
                }else{
                    reject({code:-1,msg:res.statusText,data:""});
                }
            } catch (error) {
                reject({code:-1,msg:error,data:""})
            }
        }).catch(err => {
            reject(err)
        })
    })
}